package cn.christ.com.mobilesafe.service;


import android.app.Notification;
import android.app.Service;
import android.content.Intent;
import android.os.IBinder;
import android.widget.RemoteViews;

import cn.christ.com.mobilesafe.R;

public class ProtectedService extends Service {

	@Override
	public IBinder onBind(Intent intent) {
		return null;
	}

	@Override
	public void onCreate() {
		super.onCreate();
		// 变成前台进程的服务
		// id:通知id
		// notification:通知
		Notification notification = new Notification();
		notification.icon = R.drawable.ic_contact;
		notification.contentView = new RemoteViews(getPackageName(), R.layout.view_service_notification);
		startForeground(88, notification);
	}

	@Override
	public void onDestroy() {
		super.onDestroy();
	}

}
